/**
 * API v1 路由索引
 */
const express = require('express');
const router = express.Router();

// 引入各模块路由
const helloRoutes = require('./hello/hello.routes');
const userRoutes = require('./users/users.routes');
const loginRoutes = require('./login/login.routes');

// 设置路由
router.use('/hello', helloRoutes);
router.use('/users', userRoutes);
router.use('/login',loginRoutes);

// API根路径
router.get('/', (req, res) => {
  res.json({
    message: 'Next.js 演示API v1',
    version: '1.0.0',
  });
});

module.exports = router; 